package com.coocaa.cirrus.common.base.util;

import cn.hutool.core.lang.Snowflake;
import cn.hutool.core.util.IdUtil;

import java.util.UUID;

/**
 * @author bijiahao
 * @date : 2025/7/15 15:30
 * @description
 */
public class IdCreateUtil {
    private static class Holder {
        private static final Snowflake SNOWFLAKE = IdUtil.createSnowflake(1L, 1L);
    }

    public static long getId() {
        return Holder.SNOWFLAKE.nextId();
    }

    public static String getStrId() {
        return String.valueOf(getId());
    }




    public static void main(String[] args) {
        System.out.println(getStrId());
    }
}
